{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 3.5实现线性判别分析\n",
    "编程实现线性判别分析，并给出西瓜数据集3.0alpha上的结果"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": false
   },
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "from numpy import linalg\n",
    "import matplotlib.pyplot as plt\n",
    "from sklearn import model_selection\n",
    "from sklearn.discriminant_analysis import LinearDiscriminantAnalysis"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 37,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "def get_x_y(x,y):\n",
    "    return x[np.where(y==0),0], x[np.where(y==0),1], x[np.where(y==1),0], x[np.where(y==1),1]\n",
    "\n",
    "def plot_boundary(x,y,x_train, y_train, x_test, y_test, weight):\n",
    "    xx, yy = np.meshgrid(np.arange(min(x[:,0])-0.1, max(x[:,0])+0.1, 0.01),\n",
    "                         np.arange(min(x[:,1])-0.1, max(x[:,1])+0.1, 0.01))\n",
    "    zz = weight[0]*xx + weight[1]*yy\n",
    "    f1 = plt.figure(1)   \n",
    "    plt.title('watermelon_3a')  \n",
    "    plt.xlabel('density')  \n",
    "    plt.ylabel('ratio_sugar')  \n",
    "    plt.contourf(xx,yy,zz)  \n",
    "    plt_x0, plt_y0, plt_x1, plt_y1 = get_x_y(x_train, y_train)\n",
    "    plt_xt0, plt_yt0, plt_xt1, plt_yt1 = get_x_y(x_test, y_test)\n",
    "    plt.scatter(plt_x0, plt_y0, marker = 'o', color = 'red', s=30, label = 'train_bad')\n",
    "    plt.scatter(plt_x1, plt_y1, marker = 'o', color = 'g', s=30, label = 'train_good')\n",
    "    plt.scatter(plt_xt0, plt_yt0, marker = 'x', color = 'red', s=30, label = 'test_bad')\n",
    "    plt.scatter(plt_xt1, plt_yt1, marker = 'x', color = 'g', s=30, label = 'test_good')\n",
    "    plt.legend(loc = 'upper right')\n",
    "    plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 142,
   "metadata": {
    "collapsed": false
   },
   "outputs": [],
   "source": [
    "dataset = np.loadtxt('data/watermelon_3_0_alpha.txt',delimiter=',')\n",
    "x = dataset[:,1:3]\n",
    "num_features = x.shape[1]\n",
    "# x = np.insert(x,2,values=1,axis=1)\n",
    "# x = x\n",
    "y = dataset[:, 3]\n",
    "x_train, x_test, y_train, y_test = model_selection.train_test_split(x, y, test_size=0.5, random_state=0)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 自己编写的LDA的结果"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 146,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "[[  3.71797225]\n",
      " [-26.6108442 ]]\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYYAAAEWCAYAAABi5jCmAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4yLCBo\ndHRwOi8vbWF0cGxvdGxpYi5vcmcvNQv5yAAAIABJREFUeJzt3XuczPX+wPHXe3exa9da93uSFNJF\nuXVRFB3kklCSSsjpoqOcTnW6OB1OUp2USnWQVA46SblESiE/Ra6pUMkla+Uaa9dtx75/f8xYM2sv\nM2Pu+34+HvMw3+985/t9z7S93/P5fL7f70dUFWOMMeakuHAHYIwxJrJYYTDGGOPBCoMxxhgPVhiM\nMcZ4sMJgjDHGgxUGY4wxHqwwGGOM8WCFwZgQEZE2IpIe7jiMKY4VBhOzRORpEZkc7jhCSUQWisge\nEckUke9EpFu4YzLRJyHcARgTqUQkQVUd4Y7DR0OA9arqEJGWwAIROU9Vd4Y7MBM9rMVgIpKI3CUi\ns92WN4nI/9yWt4vIJSIyxvU8U0RWiUhr1+sdgMeBW0QkS0S+c60vLyJvichOEdkhIv8SkXjXa/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AARKQt8\nD1yqqgfDHY8p2azFYEyYuebM2Ai8akXBRAJrMRhjjPFgLQZjjDEerDAYY4zxYIXBGGOMBysMxhhj\nPFhhMMYY4+H/AXQX24p2gxEHAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x9bcfb54c88>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "weight = np.ones([2,1])\n",
    "x0 = x_train[np.where(y_train==0)].T\n",
    "x1 = x_train[np.where(y_train==1)].T\n",
    "miu0 = np.mean(x0, axis = 1)\n",
    "miu1 = np.mean(x1, axis = 1)\n",
    "var0 = np.zeros([2,2])\n",
    "var1 = np.zeros([2,2])\n",
    "for i in range(len(x0)):\n",
    "    var0 += np.dot(np.reshape((x0[:,i]-miu0),[2,1]), np.reshape((x0[:,i]-miu0).T,[1,2]))\n",
    "for i in range(len(x1)):\n",
    "    var1 += np.dot(np.reshape((x1[:,i]-miu1),[2,1]), np.reshape((x1[:,i]-miu1).T,[1,2]))\n",
    "\n",
    "sw = var0 + var1\n",
    "sw_inv = linalg.inv(sw)\n",
    "weight = np.dot(sw_inv, np.reshape((miu0-miu1),[2,1]))\n",
    "\n",
    "print(weight)\n",
    "\n",
    "plot_boundary(x,y,x_train, y_train, x_test, y_test, np.ravel(weight))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 调用sklearn的结果"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 148,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "[[-17.77690732  46.51344096]]\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYYAAAEWCAYAAABi5jCmAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4yLCBo\ndHRwOi8vbWF0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
     "output_type": "display_data"
    }
   ],
   "source": [
    "lda = LinearDiscriminantAnalysis()\n",
    "lda.fit(x_train, y_train)\n",
    "print(lda.coef_)\n",
    "plot_boundary(x, y, x_train, y_train, x_test, y_test, np.ravel(lda.coef_))"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python [conda root]",
   "language": "python",
   "name": "conda-root-py"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.5.2"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}
